import 'package:agro_sklad_new/feature/domain/repositories/stock_repository.dart';
import 'package:dartz/dartz.dart';
import 'package:equatable/equatable.dart';
import 'package:agro_sklad_new/core/errors/failure.dart';
import '../../../core/usecase/usecase.dart';
import 'package:agro_sklad_new/feature/domain/entities/stock_entity.dart';



class GetAllStock extends UseCase<List<StockEntity>, StockParams>{
  final StockRepository stockRepository;


  GetAllStock(this.stockRepository);

  @override
  Future<Either<Failure, List<StockEntity>>> call(StockParams params) async{
    return await stockRepository.getAllStock();
  }
}

class StockParams extends Equatable{

  @override
  // TODO: implement props
  List<Object?> get props => throw UnimplementedError();

}